<?PHP
	require 'config.php';
	
	//connecting to DB
	$vLink = mysql_connect($DBServer, $DBUser, $DBPassword);
	if(!$vLink) 
		die(mysql_error());
	
	//setting session encoding
	mysql_select_db($DBName, $vLink);	
	mysql_query("SET NAMES 'cp1251';", $vLink);
	mysql_query("SET CHARACTER SET 'cp1251';", $vLink);
	mysql_query("SET SESSION collation_connection = 'cp1251_general_ci';", $vLink);
	
	//retrieving params
	$ID = $_GET['id'];
	
	//sending query
	$vQuery = 'DELETE FROM dikar2011_nomer WHERE id ="' . $ID . '" LIMIT 1';	
	mysql_query($vQuery);
	mysql_close($vLink);
	
	//printing update result for AS side
	echo '1';
?>